﻿using System;
using System.Collections.Generic;
using EnetaMvc.Core.Domain.Events;
using EnetaMvc.Core.Domain.News;
using EnetaMvc.Core.Domain.Forums;

namespace EnetaMvc.Core.Domain.Common
{
    public class User : BaseEntity
    {
        public virtual string UserName { get; set; }
        public virtual string Email { get; set; }
        public virtual string LiveIdToken { get; set; }
        public virtual bool Locked { get; set; }

        public virtual string FirstName { get; set; }
        public virtual string LastName { get; set; }
        public virtual string Description { get; set; }
        public virtual string HomePage { get; set; }
        public virtual string Address { get; set; }
        public virtual string Phone { get; set; }
        public virtual string School { get; set; }
        public virtual string FieldOfStudy { get; set; }
        public virtual string Company { get; set; }
        public virtual string JobTitle { get; set; }
        public virtual bool SendEventsEmails { get; set; }
        public virtual bool SendCommunityEmails { get; set; }

        public virtual bool ShowFirstName { get; set; }
        public virtual bool ShowLastName { get; set; }
        public virtual bool ShowAddress { get; set; }
        public virtual bool ShowJobTitle { get; set; }
        public virtual bool ShowEmail { get; set; }
        public virtual bool ShowFieldOfStudy { get; set; }
        public virtual bool ShowCompany { get; set; }
        public virtual bool ShowSchool { get; set; }
        public virtual bool ShowPhone { get; set; }

        public virtual DateTime Created { get; set; }
        public virtual DateTime Modified { get; set; }

        private IList<Blog> _blogs = new List<Blog>();
        private IList<EventAttendee> _eventAttendings = new List<EventAttendee>();
        private IList<MyRole> _myRoles = new List<MyRole>();
        private IList<Role> _roles = new List<Role>();
        private IList<Forum> _moderatorOf = new List<Forum>();

        public virtual IList<Blog> Blogs
        {
            get { return _blogs; }
            protected set { _blogs = value; }
        }

        public virtual IList<EventAttendee> EventAttendings
        {
            get { return _eventAttendings; }
            protected set { _eventAttendings = value; }
        }

        public virtual IList<MyRole> MyRoles
        {
            get { return _myRoles; }
            protected set { _myRoles = value; }
        }

        public virtual IList<Role> Roles
        {
            get { return _roles; }
            protected set { _roles = value; }
        }

        public virtual IList<Forum> ModeratorOf
        {
            get { return _moderatorOf; }
            protected set { _moderatorOf = value; }
        }
    }
}
